Technical Field
This disclosure relates generally to graphics processing and more specifically to texture mapping.
Description of the Related Art
Texture mapping is a well-known graphics processing technique in which a texture (e.g., an image) is applied to the surface of an object to be displayed. Textures may indicate color and transparency of pixels corresponding to object surfaces, for example.
Mipmapping is a common technique in which textures are pre-generated at multiple levels of detail (LOD). Each mipmap is a representation of the same texture at a lower resolution. This may reduce aliasing and improve performance, e.g., when textured objects are far away in a scene being rendered. The respective height and width of each mipmap is typically a power of two smaller than the previous level. For example, for an 8×16 texture, the next mipmap is 4×8, then 2×4, then 1×2 (then 1×1, for which the normal calculation breaks down and only one side is smaller than the previous mipmap).
Mipmaps are typically stored in memory together with the texture. Operations that access a texture are typically associated with a desired LOD corresponding to a desired mipmap. Based on this information, a texture processing unit must determine where the desired mipmap is stored.